﻿using System;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using cludg.Web.Core.Validation;

namespace cludg.Web.ViewModels
{
	public class PersonalInfoModel : EditUserModel
	{
		[Required(ErrorMessage = ValidationConst.RequiredMessage)]
		[StringLength(100, ErrorMessage = ValidationConst.StringLengthMaxInvalidMessage)]
		[DisplayName("Отображаемое имя")]
		public string DisplayName { get; set; }

		[DataType(DataType.DateTime)]
		[DisplayName("Дата рождения")]
		public DateTime? DateOfBirth { get; set; }

		[DisplayName("Местоположение")]
		public string Location { get; set; }

		public string Avatar { get; set; }

		[DisplayName("Аватар")]
		public string NewAvatar { get; set; }

		[DisplayName("Удалить аватар")]
		public bool DeleteAvatar { get; set; }

		public readonly string AvatarUploadFileName = "avatarUpload";
	}
}